Add io.pilot.insforge + broker-signup provisioning primitives#79
Merged
Conversation
added 2 commits
July 7, 2026 19:41
io.pilot.insforge is a byo HTTP app that provisions the caller's own isolated InsForge backend (Postgres, auth, storage, edge functions, AI model gateway) in one signed call. Pilot's insforge-signup-broker holds one managed master account and mints a per-user project; the adapter caches the key + backend URL and talks directly to that backend thereafter. - internal/insforgesignup + cmd/insforge-signup-broker: signed provisioning broker (OAuth refresh -> create project -> fetch access key), idempotent per caller, AES-GCM ledger, per-IP cap. Mirrors the otpsignup broker shape. - scaffold: backend.url_secret (per-request dynamic base URL from secrets.json, a BaseURLFunc analogue of HeaderFunc) and body_raw param location (a param's value becomes the whole request body, for bare-array APIs). Both additive. - submissions/io.pilot.insforge/submission.json: 23 methods + help, pricing on every method. - docs/BROKER-SIGNUP.md: master-account provisioning variant.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
io.pilot.insforge
InsForge (the agent-native cloud — Postgres, auth, storage, edge functions, AI model gateway) as one byo HTTP app.
insforge.signupprovisions the caller's own isolated InsForge backend in a single signed call; the adapter caches the key + backend URL and every other method talks directly to that backend, authenticated as the user.23 methods +
insforge.help, with pricing stated on every method.Broker
internal/insforgesignup+cmd/insforge-signup-broker: a signed provisioning broker that holds one managed master account and, per caller, refreshes an OAuth token, creates an InsForge project, and returns its access key + backend URL. Idempotent per caller, AES-GCM-encrypted ledger, per-IP anti-Sybil cap. Same signed-handler / ledger shape asotpsignup, without a mailbox.Two additive scaffold primitives
Needed because InsForge's backend is provisioned per user and its insert API takes a bare top-level array:
backend.url_secret— asecrets.jsonkey holding a per-user backend base URL, re-resolved per request (aBaseURLFunc, the base-URL analogue of the existing per-requestHeaderFunc). The broker-signup handler caches the returnedbackend_urlthere.body_raw— a param location whose value becomes the entire request body verbatim (bare array/scalar), the body analogue ofpath_raw.Both are opt-in and leave existing apps unchanged. Unit tests added for each; broker has its own test suite;
verify-submissionpasses for all 4 platforms.Test
go test ./internal/scaffold/ ./internal/publish/ ./internal/insforgesignup/green